package com.epam.Accessories;


public class Compressor extends Accessories {

    public Compressor(String name, double price, AccessoriesQuality quality, double power) {
        super(name, price, quality);

        this.power = power;
    }

    private double power;

    public double getPower() {
        return power;
    }

    public void setPower(double power) {
        if(power >= 1){
            this.power = power;
        }
    }


    @Override
    public String toString() {
        return "Compressor for Aquarium [ Name: "+getName()+"; Price: "+getPrice()+
               "; Quality: "+ getQuality()+"; Power: "+ getPower()+"]";
    }


}
